Handle gdk_window_get_impl_window on root window
authorAlexander Larsson <alexl@redhat.com>
Sat, 6 Dec 2008 22:01:39 +0000 (23:01 +0100)
committerAlexander Larsson <alex@localhost.localdomain>
Thu, 2 Apr 2009 08:14:07 +0000 (10:14 +0200)
gdk/gdkwindow.c

index 5830f8ae1af9035f5a2b936086f7c6ff8bfaacb7..a7424e2debf6c7fe6862fdd35de6b7943496344e 100644 (file)
@@ -385,7 +385,7 @@ gdk_window_is_offscreen (GdkWindowObject *window)
 static GdkWindowObject *
 gdk_window_get_impl_window (GdkWindowObject *window)
 {
-  while (window->parent->impl == window->impl)
+  while (window->parent != NULL && window->parent->impl == window->impl)
     window = window->parent;
 
   return window;